﻿/* 
   Copyright 2011 LUCA Studios LLC & John Evans

   Licensed under the Apache License, Version 2.0 (the "License");
   you may not use this file except in compliance with the License.
   You may obtain a copy of the License at

     http://www.apache.org/licenses/LICENSE-2.0

   Unless required by applicable law or agreed to in writing, software
   distributed under the License is distributed on an "AS IS" BASIS,
   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
   See the License for the specific language governing permissions and
   limitations under the License.
*/

namespace LUCAStudios.Silverlight.Controls.Windows
{
    using System.Windows;
    using DragDrop;

    /// <summary>
    /// Provides an interface for registering windows and working with the WindowManipulation class
    /// </summary>
    public interface IWindow : IDragDropSource, IDragDropTarget
    {
        /// <summary>
        /// Provides a boolean indicating whether the WindowManipulation class should honor window resize requests from the user.
        /// </summary>
        bool ResizeEnabled { get; }

        /// <summary>
        /// The visual element representing the resize-top operation to the user.  Assign to null if not using.
        /// </summary>
        FrameworkElement HeightResizerTop { get; }
        /// <summary>
        /// The visual element representing the resize-bottom operation to the user.  Assign to null if not using.
        /// </summary>
        FrameworkElement HeightResizerBottom { get; }
        /// <summary>
        /// The visual element representing the resize-left operation to the user.  Assign to null if not using.
        /// </summary>
        FrameworkElement WidthResizerLeft { get; }
        /// <summary>
        /// The visual element representing the resize-right operation to the user.  Assign to null if not using.
        /// </summary>
        FrameworkElement WidthResizerRight { get; }
        /// <summary>
        /// The visual element representing the resize-top/left operation to the user.  Assign to null if not using.
        /// </summary>
        FrameworkElement ResizerTopLeft { get; }
        /// <summary>
        /// The visual element representing the resize-top/left operation to the user.  Assign to null if not using.
        /// </summary>
        FrameworkElement ResizerTopRight { get; }
        /// <summary>
        /// The visual element representing the resize-bottom/right operation to the user.  Assign to null if not using.
        /// </summary>
        FrameworkElement ResizerBottomRight { get; }
        /// <summary>
        /// The visual element representing the resize-bottom/left operation to the user.  Assign to null if not using.
        /// </summary>
        FrameworkElement ResizerBottomLeft { get; }
        /// <summary>
        /// Constrains any resize activity to a minimum width value.
        /// </summary>
        double MinimumWindowWidth { get; }
        /// <summary>
        /// Constrains any resize activity to a minimum height value.
        /// </summary>
        double MinimumWindowHeight { get; }

        /// <summary>
        /// Called when resize operation begins on window
        /// </summary>
        void OnResizeStarted();

        /// <summary>
        /// Called when resize operation completes on window
        /// </summary>
        void OnResizeEnded();

    }
}
